package com.kaibes.platform.currency.listener;

import org.springframework.beans.factory.annotation.Autowired;

import com.kaibes.module.user.UserService;
import com.kaibes.orm.core.listener.DeleteListener;
import com.kaibes.orm.curd.Delete;
import com.kaibes.orm.spring.OrmListener;
import com.kaibes.platform.currency.db.CurrencyUserService;

@OrmListener(service = UserService.class)
public class UserDeleteListener4Currency implements DeleteListener {

    @Autowired
    private CurrencyUserService currencyUserService;
    
    @Override
    public void afterDelete(Delete delete, int count) throws Exception {
        currencyUserService.clearCache();
    }
}
